package org.aepscolombia.platform.models.entity;
// Generated Apr 8, 2014 9:37:27 AM by Hibernate Tools 3.2.1.GA


import java.util.Date;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * Harvests generated by hbm2java
 */
@Entity
@Table(name="harvests")
public class Harvests  implements java.io.Serializable {


     private Integer idHar;
     private ResultingProducts resultingProducts;
     private HarvestMethods harvestMethods;
     private ProductionEvents productionEvents;
     private Date dateHar;
     private String commentHar;
     private Integer productionHar;
     private Double yieldHar;
     private Boolean storageHar;
     private Double productionPerPlantHar;
     private Double humidityPercentageHar;
     private Integer numberSacksSow;
     private Double weightAvgSacksSow;
     private Double loadHectareSow;
     private Boolean status;
     private Integer createdBy;

    public Harvests() {
    }

	
    public Harvests(ProductionEvents productionEvents, Date dateHar, Integer productionHar, Double yieldHar) {
        this.productionEvents = productionEvents;
        this.dateHar = dateHar;
        this.productionHar = productionHar;
        this.yieldHar = yieldHar;
    }
    
    public Harvests(ResultingProducts resultingProducts, HarvestMethods harvestMethods, ProductionEvents productionEvents, Date dateHar, String commentHar, Integer productionHar, Double yieldHar, Boolean storageHar, Double productionPerPlantHar, Double humidityPercentageHar, Integer numberSacksSow, Double weightAvgSacksSow, Double loadHectareSow, Boolean status, Integer createdBy) {
       this.resultingProducts = resultingProducts;
       this.harvestMethods = harvestMethods;
       this.productionEvents = productionEvents;
       this.dateHar = dateHar;
       this.commentHar = commentHar;
       this.productionHar = productionHar;
       this.yieldHar = yieldHar;
       this.storageHar = storageHar;
       this.productionPerPlantHar = productionPerPlantHar;
       this.humidityPercentageHar = humidityPercentageHar;
       this.numberSacksSow = numberSacksSow;
       this.weightAvgSacksSow = weightAvgSacksSow;
       this.loadHectareSow = loadHectareSow;
       this.status = status;
       this.createdBy = createdBy;
    }
   
     @Id @GeneratedValue(strategy=IDENTITY)
    
    @Column(name="id_har", unique=true, nullable=false)
    public Integer getIdHar() {
        return this.idHar;
    }
    
    public void setIdHar(Integer idHar) {
        this.idHar = idHar;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="expected_product_type_har")
    public ResultingProducts getResultingProducts() {
        return this.resultingProducts;
    }
    
    public void setResultingProducts(ResultingProducts resultingProducts) {
        this.resultingProducts = resultingProducts;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="method_har")
    public HarvestMethods getHarvestMethods() {
        return this.harvestMethods;
    }
    
    public void setHarvestMethods(HarvestMethods harvestMethods) {
        this.harvestMethods = harvestMethods;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="id_production_event_har", nullable=false)
    public ProductionEvents getProductionEvents() {
        return this.productionEvents;
    }
    
    public void setProductionEvents(ProductionEvents productionEvents) {
        this.productionEvents = productionEvents;
    }
    @Temporal(TemporalType.TIMESTAMP)
    @Column(name="date_har", length=19)
    public Date getDateHar() {
        return this.dateHar;
    }
    
    public void setDateHar(Date dateHar) {
        this.dateHar = dateHar;
    }
    
    @Column(name="comment_har", length=65535)
    public String getCommentHar() {
        return this.commentHar;
    }
    
    public void setCommentHar(String commentHar) {
        this.commentHar = commentHar;
    }
    
    @Column(name="production_har")
    public Integer getProductionHar() {
        return this.productionHar;
    }
    
    public void setProductionHar(Integer productionHar) {
        this.productionHar = productionHar;
    }
    
    @Column(name="yield_har", precision=22, scale=0)
    public Double getYieldHar() {
        return this.yieldHar;
    }
    
    public void setYieldHar(Double yieldHar) {
        this.yieldHar = yieldHar;
    }
    
    @Column(name="storage_har")
    public Boolean getStorageHar() {
        return this.storageHar;
    }
    
    public void setStorageHar(Boolean storageHar) {
        this.storageHar = storageHar;
    }
    
    @Column(name="production_per_plant_har", precision=22, scale=0)
    public Double getProductionPerPlantHar() {
        return this.productionPerPlantHar;
    }
    
    public void setProductionPerPlantHar(Double productionPerPlantHar) {
        this.productionPerPlantHar = productionPerPlantHar;
    }
    
    @Column(name="humidity_percentage_har", precision=22, scale=0)
    public Double getHumidityPercentageHar() {
        return this.humidityPercentageHar;
    }
    
    public void setHumidityPercentageHar(Double humidityPercentageHar) {
        this.humidityPercentageHar = humidityPercentageHar;
    }
    @Column(name="number_sacks_sow")
    public Integer getNumberSacksSow() {
        return this.numberSacksSow;
    }
    
    public void setNumberSacksSow(Integer numberSacksSow) {
        this.numberSacksSow = numberSacksSow;
    }
    
    @Column(name="weight_avg_sacks_sow", precision=22, scale=0)
    public Double getWeightAvgSacksSow() {
        return this.weightAvgSacksSow;
    }
    
    public void setWeightAvgSacksSow(Double weightAvgSacksSow) {
        this.weightAvgSacksSow = weightAvgSacksSow;
    }
    
    @Column(name="load_hectare_sow", precision=22, scale=0)
    public Double getLoadHectareSow() {
        return this.loadHectareSow;
    }
    
    public void setLoadHectareSow(Double loadHectareSow) {
        this.loadHectareSow = loadHectareSow;
    }
    
    @Column(name="status")
    public Boolean getStatus() {
        return this.status;
    }
    
    public void setStatus(Boolean status) {
        this.status = status;
    }
    
    @Column(name="created_by")
    public Integer getCreatedBy() {
        return this.createdBy;
    }
    
    public void setCreatedBy(Integer createdBy) {
        this.createdBy = createdBy;
    }
    
}


